package com.xiangban.feign.fallBack;

import com.xiangban.feign.DoctorFeign;
import com.xiangban.feign.MessageFeign;
import com.xiangban.model.SmsParameterDto;
import com.xiangban.model.res.ApiResult;
import feign.hystrix.FallbackFactory;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.util.HashMap;

/**
 * @Author Mr. MaYaYun
 * @Data 2021/12/31 12:20
 */
@Component
@Slf4j
public class MessageFallback implements FallbackFactory<MessageFeign> {
    public MessageFeign create(Throwable throwable) {
        return new MessageFeign() {


            @Override
            public ApiResult<Object> sendSms(SmsParameterDto smsParameterDto) {

                return null;
            }
        };
    }
}
